import { Pipe, PipeTransform } from '@angular/core';

@Pipe({
  name: 'formatCName',
})
export class FormatCNamePipe implements PipeTransform {
  transform(value: string): string {
    if (value.length >= 3) {
      return value;
    } else {
      return value[0] + '　' + value[1];
    }
  }
}
